package com.yitiao.designmodel.behave.strategy;

import java.util.HashMap;
import java.util.Map;

public class MainTest {
    public static Map<String,RejectStrategy> map = new HashMap();

    public static void main(String[] args) {
        initRejectMap();
        RejectService overWork = new RejectService(map.get("direct"));
        overWork.rejectWork();
    }

//    @PostConstruct
    public static void initRejectMap(){
        map.put("direct",new DirectReject());
        map.put("indirect",new IndirectReject());
    }
}
